package com.yc.baihe.beans;

import java.io.Serializable;
import com.yc.baihe.utils.AgeUtil;

public class UserList implements Serializable{
	private static final long serialVersionUID = 1L;
	private int buid;//用户账号
	private String nickname;//昵称
	private String touxiang;//头像
	private String uname;//真实姓名
	private int txStatus;//0.头像未审核    1.审核通过     2.审核未通过
	private String sex;//性别
	private String birthday;//出生日期
	private String animal;//属相
	private String constellation;//星座
	private String hometown;//家乡
	private String xianarea;//现居地
	private String height;//身高
	private String education;//学历
	private String works;//职位
	private String income;//收入
	private String marriage;//婚姻状态
	private String children;//子女情况
	private String ifhome;//购房情况
	private String ifchar;//购车情况
	private String looks;//性格
	private String contents;//自我介绍
	private String temp1;//备用
	private String temp2;//备用
	
	@Override
	public String toString() {
		return "UserList [buid=" + buid + ", nickname=" + nickname
				+ ", touxiang=" + touxiang + ", uname=" + uname + ", txStatus="
				+ txStatus + ", sex=" + sex + ", birthday=" + birthday
				+ ", animal=" + animal + ", constellation=" + constellation
				+ ", hometown=" + hometown + ", xianarea=" + xianarea
				+ ", height=" + height + ", education=" + education
				+ ", works=" + works + ", income=" + income + ", marriage="
				+ marriage + ", children=" + children + ", ifhome=" + ifhome
				+ ", ifchar=" + ifchar + ", looks=" + looks + ", contents="
				+ contents + ", temp1=" + temp1 + ", temp2=" + temp2 + "]";
	}

	public String getInfor(){
		int age=AgeUtil.getAge(birthday);
		return buid+"\n"+age+"\n"+sex+"\n"+looks;
	}
	
	public int getBuid() {
		return buid;
	}

	public void setBuid(int buid) {
		this.buid = buid;
	}

	public String getNickname() {
		return nickname;
	}

	public void setNickname(String nickname) {
		this.nickname = nickname;
	}

	public String getTouxiang() {
		return touxiang;
	}
	public String getTouxiangs(){
		if(touxiang==null || "".equals(touxiang)){
			if("清新单纯".equals(looks)){
				return "people/girl/qxdc.jpg";
			}else if("妩媚动人".equals(looks)){
				return "people/girl/wmdr.jpg";
			}else if("年轻有为".equals(looks)){
				return "people/boy/nqyw.jpg";
			}else if("温文尔雅".equals(looks)){
				return "people/boy/wwey.jpg";
			}
		}
		return touxiang;
		
	}

	public void setTouxiang(String touxiang) {
		this.touxiang = touxiang;
	}

	public String getUname() {
		return uname;
	}

	public void setUname(String uname) {
		this.uname = uname;
	}

	public int getTxStatus() {
		return txStatus;
	}

	public void setTxStatus(int txStatus) {
		this.txStatus = txStatus;
	}

	public String getSex() {
		return sex;
	}

	public void setSex(String sex) {
		this.sex = sex;
	}

	public String getBirthday() {
		return birthday;
	}

	public void setBirthday(String birthday) {
		this.birthday = birthday;
	}

	public String getAnimal() {
		return animal;
	}

	public void setAnimal(String animal) {
		this.animal = animal;
	}

	public String getConstellation() {
		return constellation;
	}

	public void setConstellation(String constellation) {
		this.constellation = constellation;
	}

	public String getHometown() {
		return hometown;
	}

	public void setHometown(String hometown) {
		this.hometown = hometown;
	}

	public String getXianarea() {
		return xianarea;
	}

	public void setXianarea(String xianarea) {
		this.xianarea = xianarea;
	}

	public String getHeight() {
		return height;
	}

	public void setHeight(String height) {
		this.height = height;
	}

	public String getEducation() {
		return education;
	}

	public void setEducation(String education) {
		this.education = education;
	}

	public String getWorks() {
		return works;
	}

	public void setWorks(String works) {
		this.works = works;
	}

	public String getIncome() {
		return income;
	}

	public void setIncome(String income) {
		this.income = income;
	}

	public String getMarriage() {
		return marriage;
	}

	public void setMarriage(String marriage) {
		this.marriage = marriage;
	}

	public String getChildren() {
		return children;
	}

	public void setChildren(String children) {
		this.children = children;
	}

	public String getIfhome() {
		return ifhome;
	}

	public void setIfhome(String ifhome) {
		this.ifhome = ifhome;
	}

	public String getifchar() {
		return ifchar;
	}

	public void setifchar(String ifchar) {
		this.ifchar = ifchar;
	}

	public String getLooks() {
		return looks;
	}

	public void setLooks(String looks) {
		this.looks = looks;
	}

	public String getContents() {
		return contents;
	}

	public void setContents(String contents) {
		this.contents = contents;
	}

	public String getTemp1() {
		return temp1;
	}

	public void setTemp1(String temp1) {
		this.temp1 = temp1;
	}

	public String getTemp2() {
		return temp2;
	}

	public void setTemp2(String temp2) {
		this.temp2 = temp2;
	}

	public static long getSerialversionuid() {
		return serialVersionUID;
	}

	public UserList(int buid, String nickname, String touxiang, String uname,
			int txStatus, String sex, String birthday, String animal,
			String constellation, String hometown, String xianarea,
			String height, String education, String works, String income,
			String marriage, String children, String ifhome, String ifchar,
			String looks, String contents, String temp1, String temp2) {
		super();
		this.buid = buid;
		this.nickname = nickname;
		this.touxiang = touxiang;
		this.uname = uname;
		this.txStatus = txStatus;
		this.sex = sex;
		this.birthday = birthday;
		this.animal = animal;
		this.constellation = constellation;
		this.hometown = hometown;
		this.xianarea = xianarea;
		this.height = height;
		this.education = education;
		this.works = works;
		this.income = income;
		this.marriage = marriage;
		this.children = children;
		this.ifhome = ifhome;
		this.ifchar = ifchar;
		this.looks = looks;
		this.contents = contents;
		this.temp1 = temp1;
		this.temp2 = temp2;
	}

	public UserList() {
		super();
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((animal == null) ? 0 : animal.hashCode());
		result = prime * result
				+ ((birthday == null) ? 0 : birthday.hashCode());
		result = prime * result + buid;
		result = prime * result
				+ ((children == null) ? 0 : children.hashCode());
		result = prime * result
				+ ((constellation == null) ? 0 : constellation.hashCode());
		result = prime * result
				+ ((contents == null) ? 0 : contents.hashCode());
		result = prime * result
				+ ((education == null) ? 0 : education.hashCode());
		result = prime * result + ((height == null) ? 0 : height.hashCode());
		result = prime * result
				+ ((hometown == null) ? 0 : hometown.hashCode());
		result = prime * result + ((ifchar == null) ? 0 : ifchar.hashCode());
		result = prime * result + ((ifhome == null) ? 0 : ifhome.hashCode());
		result = prime * result + ((income == null) ? 0 : income.hashCode());
		result = prime * result + ((looks == null) ? 0 : looks.hashCode());
		result = prime * result
				+ ((marriage == null) ? 0 : marriage.hashCode());
		result = prime * result
				+ ((nickname == null) ? 0 : nickname.hashCode());
		result = prime * result + ((sex == null) ? 0 : sex.hashCode());
		result = prime * result + ((temp1 == null) ? 0 : temp1.hashCode());
		result = prime * result + ((temp2 == null) ? 0 : temp2.hashCode());
		result = prime * result
				+ ((touxiang == null) ? 0 : touxiang.hashCode());
		result = prime * result + txStatus;
		result = prime * result + ((uname == null) ? 0 : uname.hashCode());
		result = prime * result + ((works == null) ? 0 : works.hashCode());
		result = prime * result
				+ ((xianarea == null) ? 0 : xianarea.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		UserList other = (UserList) obj;
		if (animal == null) {
			if (other.animal != null)
				return false;
		} else if (!animal.equals(other.animal))
			return false;
		if (birthday == null) {
			if (other.birthday != null)
				return false;
		} else if (!birthday.equals(other.birthday))
			return false;
		if (buid != other.buid)
			return false;
		if (children == null) {
			if (other.children != null)
				return false;
		} else if (!children.equals(other.children))
			return false;
		if (constellation == null) {
			if (other.constellation != null)
				return false;
		} else if (!constellation.equals(other.constellation))
			return false;
		if (contents == null) {
			if (other.contents != null)
				return false;
		} else if (!contents.equals(other.contents))
			return false;
		if (education == null) {
			if (other.education != null)
				return false;
		} else if (!education.equals(other.education))
			return false;
		if (height == null) {
			if (other.height != null)
				return false;
		} else if (!height.equals(other.height))
			return false;
		if (hometown == null) {
			if (other.hometown != null)
				return false;
		} else if (!hometown.equals(other.hometown))
			return false;
		if (ifchar == null) {
			if (other.ifchar != null)
				return false;
		} else if (!ifchar.equals(other.ifchar))
			return false;
		if (ifhome == null) {
			if (other.ifhome != null)
				return false;
		} else if (!ifhome.equals(other.ifhome))
			return false;
		if (income == null) {
			if (other.income != null)
				return false;
		} else if (!income.equals(other.income))
			return false;
		if (looks == null) {
			if (other.looks != null)
				return false;
		} else if (!looks.equals(other.looks))
			return false;
		if (marriage == null) {
			if (other.marriage != null)
				return false;
		} else if (!marriage.equals(other.marriage))
			return false;
		if (nickname == null) {
			if (other.nickname != null)
				return false;
		} else if (!nickname.equals(other.nickname))
			return false;
		if (sex == null) {
			if (other.sex != null)
				return false;
		} else if (!sex.equals(other.sex))
			return false;
		if (temp1 == null) {
			if (other.temp1 != null)
				return false;
		} else if (!temp1.equals(other.temp1))
			return false;
		if (temp2 == null) {
			if (other.temp2 != null)
				return false;
		} else if (!temp2.equals(other.temp2))
			return false;
		if (touxiang == null) {
			if (other.touxiang != null)
				return false;
		} else if (!touxiang.equals(other.touxiang))
			return false;
		if (txStatus != other.txStatus)
			return false;
		if (uname == null) {
			if (other.uname != null)
				return false;
		} else if (!uname.equals(other.uname))
			return false;
		if (works == null) {
			if (other.works != null)
				return false;
		} else if (!works.equals(other.works))
			return false;
		if (xianarea == null) {
			if (other.xianarea != null)
				return false;
		} else if (!xianarea.equals(other.xianarea))
			return false;
		return true;
	}
	
}
